export CC  = gcc
export CXX = g++
export CFLAGS = -Wall -O3 -msse2 -std=c++0x
#export CFLAGS = -Wall -g -O0
export LDFLAGS= -pthread -lm

# specify tensor path                                                                                                                                        

BIN = mkAcntNext mkCatHist mkSessionNext mkSessionPrev mkUserActWeek mkUserAPM transSessionGap mkSnsStar mkStarImfb evaluateAP
OBJ =

.PHONY: clean all

all: $(BIN)


$(BIN) :
	$(CXX) $(CFLAGS) $(LDFLAGS) -o $@ $(filter %.cpp %.o %.c, $^)

$(OBJ) :
	$(CXX) -c $(CFLAGS) -o $@ $(filter %.cpp %.c, $^)

clean:
	$(RM) $(OBJ) $(BIN) *~

mkAcntNext: mkAcntNext.cpp
mkCatHist: mkCatHist.cpp
mkSessionNext: mkSessionNext.cpp
mkSessionPrev: mkSessionPrev.cpp
mkUserActWeek: mkUserActWeek.cpp
mkUserAPM: mkUserAPM.cpp
transSessionGap: transSessionGap.cpp
mkSnsStar: mkSnsStar.cpp
mkStarImfb: mkStarImfb.cpp
evaluateAP: evaluateAP.cpp
